#define _CRT_SECURE_NO_WARNINGS 1

#include<iostream>
using namespace std;

class StackOnly
{
public:
	static StackOnly CreateObj()
	{
		return StackOnly();
	}

	void* operator new(size_t size) = delete;
	void operator delete(void* p) = delete;
private:
	StackOnly()
		:_a(0)
	{}
private:
	int _a;
};

int main()
{
	StackOnly s = StackOnly::CreateObj();
	StackOnly s1;
	static StackOnly sss;
	return 0;
}